home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Shareware Grab Bag
/
Shareware Grab Bag.iso
/
050
/
turbo_t1.arc
/
PROG5.PAS
< prev
next >
Wrap
Pascal/Delphi Source File
|
1985-05-27
|
680b
|
28 lines
PROGRAM PROG5;
{$U+ Copyright (C), 1985 by Lyle Faurot. All rights reserved.
New Topics: Integer Expressions
}
VAR
I, J, I_Cubed : Integer;
BEGIN
WriteLn('When entering more than one number at once, ');
WriteLn('use a space to separate the numbers entered.');
WriteLn;
Write('Enter two numbers: ');
ReadLn(I, J);
WriteLn;
WriteLn('I = ',I,' J = ',J);
WriteLn;
WriteLn('I + J = ',I + J); {The expression may be calculated }
WriteLn('I - J = ',I - J); {within the WriteLn statement }
I_Cubed := I * I * I; {or in a separate assignment statement }
WriteLn('The cube of I = ',I_Cubed);
END.